<?php

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
$arr = array(
    'tuser_permission' => array('idxu_parentID' => 'id,parentID,isMenu'),
    'tuser_member' => array('idx_userType' => 'userType', 'idxu_siteID' => 'userType,siteID', 'idx_userName' => 'userName'),
    'tcti_task' => array('idx_taskStrategyID' => 'taskStrategyID'),
    'tcti_task_strategy' => array('idx_siteID' => 'siteID'),
    'cdr' => array('idxu_extension' => 'extension,dst',),
    'tcti_call_number' => array('idxu_taskID' => 'taskID,taskStrategyID', 'idx_taskID' => 'taskID', 'idx_taskStrategyID' => 'taskStrategyID'),
);

foreach ($arr as $table => $idies) {
    foreach ($idies as $idx => $fields) {
        echo '<div>ALTER TABLE ', $table, ' ADD INDEX ', $idx, ' (', $fields, ');</div>';
    }
}